    $(function(){
        berserker.addView({
            name:'yypp',
            tpl:'tpl_yypp',
            dataURL:'/api/yypp.json',
            beforeRender:function(host){
                var chartEvent={};
                chartEvent['yypp-chart1'] = {
                    plotOptions: {
                        series:{
                            cursor: 'pointer'
                        }
                    }
                }
                chartEvent['yypp-chart2']={
                    plotOptions: {
                        pie: {
                            allowPointSelect: true,cursor: 'pointer',
                            showInLegend:true,
                            dataLabels: {
                                enabled: false,
                                color: '#000000',
                                connectorColor: '#000000',
                                formatter: function() {
                                    return '<b>'+ this.point.name +'</b>: '+ this.percentage +' %';
                                }
                            }
                        }
                    }
                }
                host.data('chartEvent',chartEvent);
            },
            done:function(host){
                //绑定tab view

                //$(".tabview > ul",host).tabs(".tabview > .tabContent");

                //new iScroll($('[data-role=kswrap]',host)[0],{hScroll:true,vScrollbar:true});
                if(!$(".tabview .tab:last",host).attr('scrolled')){
                    $(".tabview .tab:last",host).attr('scrolled',true).click(function(){
                        setTimeout(function(){
                            new iScroll($('[data-role=kswrap]',host)[0],{snap:true});
                        },100)
                    })
                }

                $('.slidetabs').jcarousel({
                    auto: 2,
                    wrap: 'last',
                    scroll:1,
                    animation:'slow'
                    //,initCallback: mycarousel_initCallback
                });

//                $(".slidetabs-nav").tabs(".slidetabs > div", {
//                    effect: 'fade',
//                    fadeOutSpeed: "fast",
//                    autoplay:true,
//                    interval:500,
//                    rotate: true
//                }).slideshow();
            }
        })
    })
